package com.resys.entity.po;

import com.fasterxml.jackson.annotation.JsonIgnore;
import java.math.BigDecimal;
import java.util.Date;
import com.resys.entity.enums.DateTimePatternEnum;
import com.resys.utils.DateUtil;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;


/**
 * 
 */
public class Cancellationrequest implements Serializable {


	/**
	 * 
	 */
	private Integer cancellationId;

	/**
	 * 
	 */
	private Integer orderId;

	/**
	 * 
	 */
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date requestTime;

	/**
	 * 
	 */
	private BigDecimal refundAmount;

	/**
	 * 0=pending, 1=approved, 2=rejected
	 */
	private Integer status;

	/**
	 * 
	 */
	private String processedBy;

	/**
	 * 
	 */
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date processedTime;


	public void setCancellationId(Integer cancellationId){
		this.cancellationId = cancellationId;
	}

	public Integer getCancellationId(){
		return this.cancellationId;
	}

	public void setOrderId(Integer orderId){
		this.orderId = orderId;
	}

	public Integer getOrderId(){
		return this.orderId;
	}

	public void setRequestTime(Date requestTime){
		this.requestTime = requestTime;
	}

	public Date getRequestTime(){
		return this.requestTime;
	}

	public void setRefundAmount(BigDecimal refundAmount){
		this.refundAmount = refundAmount;
	}

	public BigDecimal getRefundAmount(){
		return this.refundAmount;
	}

	public void setStatus(Integer status){
		this.status = status;
	}

	public Integer getStatus(){
		return this.status;
	}

	public void setProcessedBy(String processedBy){
		this.processedBy = processedBy;
	}

	public String getProcessedBy(){
		return this.processedBy;
	}

	public void setProcessedTime(Date processedTime){
		this.processedTime = processedTime;
	}

	public Date getProcessedTime(){
		return this.processedTime;
	}

	@Override
	public String toString (){
		return "cancellationId:"+(cancellationId == null ? "空" : cancellationId)+"，orderId:"+(orderId == null ? "空" : orderId)+"，requestTime:"+(requestTime == null ? "空" : DateUtil.format(requestTime, DateTimePatternEnum.YYYY_MM_DD_HH_MM_SS.getPattern()))+"，refundAmount:"+(refundAmount == null ? "空" : refundAmount)+"，0=pending, 1=approved, 2=rejected:"+(status == null ? "空" : status)+"，processedBy:"+(processedBy == null ? "空" : processedBy)+"，processedTime:"+(processedTime == null ? "空" : DateUtil.format(processedTime, DateTimePatternEnum.YYYY_MM_DD_HH_MM_SS.getPattern()));
	}
}
